<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>过渡</title>

        <style>

            #box {
                width: 100px;
                height: 100px;
                background-color: black;

                /* 第一个值表示要过渡的属性 */
                /* 如果要所有属性都参与过渡，可以写all
                  transition: all 1s linear 0s; */
                transition: all 0.5s ease-in 2s;
                /* transition-property: background-color;
                transition-duration: 0.5s;
                transition-timing-function: ease-in-out; */
                /* transition-delay: 2s; */

            }

            #box:hover {
                width: 1000px;
                background-color: red;
            }
        </style>
    </head>
    <body>
        <div id="box"></div>
    </body>
</html>